/*
 * Copyright (C) 2010 TopCoder Inc., All Rights Reserved.
 */
package com.hercules.android.receiver.entities;

import android.widget.VideoView;

/**
 * <p>
 * A POJO contains the data of XREVideo resource.
 * </p>
 * 
 * @author TCSASSEMBER
 * @version 1.0
 */
public class XREVideo extends XREObject {
    /**
     * Represents the URL to the video.
     */
    private String url;

    /**
     * Represents the volume level.
     */
    private Integer volume;

    /**
     * Indicates whether the video will begin playing immediately after it is
     * loaded.
     */
    private Boolean autoPlay;

    /**
     * Indicates the speed at which the video will play.
     */
    private Double speed;

    /**
     * The content type of the audio content.
     */
    private String contentType;

    /**
     * Represents the <code>VideoView</code> of this video content.
     */
    private VideoView videoView;

    /**
     * Default constructor. Set the default values.
     */
    public XREVideo() {
        super();
        volume = 100;
        autoPlay = true;
        speed = 1.0;
    }

    /**
     * Sets the URL to the video content.
     * 
     * @return the URL to the video content.
     */
    public String getUrl() {
        return url;
    }

    /**
     * Sets the URL to the video content.
     * 
     * @param url
     *            the URL to the video content.
     */
    public void setUrl(String url) {
        this.url = url;
    }

    /**
     * Gets the volume level.
     * 
     * @return the volume level.
     */
    public Integer getVolume() {
        return volume;
    }

    /**
     * Sets the volume level.
     * 
     * @param volume
     *            the volume level.
     */
    public void setVolume(Integer volume) {
        this.volume = volume;
    }

    /**
     * Gets whether the video will begin playing immediately after it is loaded.
     * 
     * @return whether the video will begin playing immediately after it is
     *         loaded.
     */
    public Boolean getAutoPlay() {
        return autoPlay;
    }

    /**
     * Sets whether the video will begin playing immediately after it is loaded.
     * 
     * @param autoPlay
     *            whether the video will begin playing immediately after it is
     *            loaded.
     */
    public void setAutoPlay(Boolean autoPlay) {
        this.autoPlay = autoPlay;
    }

    /**
     * Gets the speed at which the video will play.
     * 
     * @return the speed at which the video will play.
     */
    public Double getSpeed() {
        return speed;
    }

    /**
     * Sets the speed at which the video will play.
     * 
     * @param speed
     *            the speed at which the video will play.
     */
    public void setSpeed(Double speed) {
        this.speed = speed;
    }

    /**
     * Gets the content type of the audio content.
     * 
     * @return the content type of the audio content.
     */
    public String getContentType() {
        return contentType;
    }

    /**
     * Sets the content type of the audio content.
     * 
     * @param contentType
     *            the content type of the audio content.
     */
    public void setContentType(String contentType) {
        this.contentType = contentType;
    }

    /**
     * Gets the <code>VideoView</code> of the video content.
     * 
     * @return the <code>VideoView</code> of the video content.
     */
    public VideoView getVideoView() {
        return videoView;
    }

    /**
     * Sets the <code>VideoView</code> of the video content..
     * 
     * @param videoView
     *            the <code>VideoView</code> of the video content.
     */
    public void setVideoView(VideoView videoView) {
        this.videoView = videoView;
    }
}
